waterinfo

Want to know waterinfo? we have a huge selection of waterinfo information on alibabacloud.com

PHP Image Processing Class

for the bottom of the right;* @param string $QZ The file name of the image after the watermark is prefixed with the original file name* @return Mixed is the name of the image after the watermark is generated, the failure returns false*/function WaterMark ($groundName, $waterName, $waterPos =0, $QZ = "Wa_") {/* Gets the watermark picture is the current path, or the path is specified */$curpath = RTrim ($this->path, "/"). " /";$dir = DirName ($waterName);if ($dir = = ".") {$wpath = $curpath;}else

PHP Implementation Image Add watermark function

, $savepath =null, $savename =null, $positon =5, $alpha =30) {nbsp; nbsp; $temp = PathInfo ($SRCIMG); nbsp; nbsp; $name = $t emp[' basename ']; nbsp; nbsp; $path = $temp [' dirname ']; nbsp; nbsp; $exte = $temp [' extension ']; nbsp; nbsp; $savename = $savename? $savename: $name; nbsp; nbsp; $savepath = $savepath? $savepath: $path; nbsp; nbsp; $savefile = $savepath. ' /'. $savename; nbSp nbsp; $srcinfo = @getimagesize ($SRCIMG); nbsp; nbsp; if (! $srcinfo) {nbsp; nbsp; nbsp; nbsp; return-1;//ori

PHP Implementation Image add watermark function _php Tutorial

; $savepath = $savepath? $savepath: $path; $savefile = $savepath. ' /'. $savename; $srcinfo = @getimagesize ($SRCIMG); if (! $srcinfo) { return-1; The original file does not exist } $waterinfo = @getimagesize ($WATERIMG); if (! $waterinfo) { Return-2; Watermark picture does not exist } $SRCIMGOBJ = Image_create_from_ext ($SRCIMG); if (! $srcImgObj) { return-3; The original file image object failed to build

PHP Add a watermark to a picture _php tutorial

= $savepath./. $savename; $srcinfo = @getimagesize ($SRCIMG); if (! $srcinfo) { return-1; The original file does not exist } $waterinfo = @getimagesize ($WATERIMG); if (! $waterinfo) { Return-2; Watermark picture does not exist } $SRCIMGOBJ = Image_create_from_ext ($SRCIMG); if (! $srcImgObj) { return-3; The original file image object failed to build } $WATERIMGOBJ = Image_create_from_ext ($WATERIMG); if (

Php image watermark function, php image watermark function code example

img_water_mark ($ srcImg, $ waterImg, $ savepath = null, $ savename = null, $ positon = 5, $ alpha = 30) { $ Temp = pathinfo ($ srcImg ); $ Name = $ temp ['basename']; $ Path = $ temp ['dirname']; $ Exte = $ temp ['extension']; $ Savename = $ savename? $ Savename: $ name; $ Savepath = $ savepath? $ Savepath: $ path; $ Savefile = $ savepath. '/'. $ savename; $ Srcinfo = @ getimagesize ($ srcImg ); If (! $ Srcinfo ){ Return-1; // The original

Simple example of adding a watermark to a php image

= null, $ positon = 5, $ alpha = 30) { $ Temp = pathinfo ($ srcImg ); $ Name = $ temp ['basename']; $ Path = $ temp ['dirname']; $ Exte = $ temp ['extension']; $ Savename = $ savename? $ Savename: $ name; $ Savepath = $ savepath? $ Savepath: $ path; $ Savefile = $ savepath. '/'. $ savename; $ Srcinfo = @ getimagesize ($ srcImg ); If (! $ Srcinfo ){ Return-1; // The original file does not exist. } $

Php allows you to add watermarks to images.

'];$ Savename = $ savename? $ Savename: $ name;$ Savepath = $ savepath? $ Savepath: $ path;$ Savefile = $ savepath. '/'. $ savename;$ Srcinfo = @ getimagesize ($ srcImg );If (! $ Srcinfo ){Return-1; // the original file does not exist.}$ Waterinfo = @ getimagesize ($ waterImg );If (! $ Waterinfo ){Return-2; // The watermark image does not exist.}$ SrcImgObj = image_create_from_ext ($ srcImg );If (! $ SrcImg

PHP to add a watermark instance function to the picture

Success--New image address after watermark* Failed---1: Original file does not exist,-2: Watermark picture does not exist,-3: Original file image Object build failed*-4: Watermark file Image Object build failed-5: New picture after Watermark failed to save*/function Img_water_mark ($SRCIMG, $WATERIMG, $savepath =null, $savename =null, $positon =5, $alpha =30){$temp = PathInfo ($SRCIMG);$name = $temp [basename];$path = $temp [dirname];$exte = $temp [extension];$savename = $savename? $savename: $

Add watermarks to images using php

: $ name;$ Savepath = $ savepath? $ Savepath: $ path;$ Savefile = $ savepath./. $ savename;$ Srcinfo = @ getimagesize ($ srcImg );If (! $ Srcinfo ){Return-1; // the original file does not exist.}$ Waterinfo = @ getimagesize ($ waterImg );If (! $ Waterinfo ){Return-2; // The watermark image does not exist.}$ SrcImgObj = image_create_from_ext ($ srcImg );If (! $ SrcImgObj ){Return-3; // failed to create the o

Php _ PHP Tutorial for adding watermarks to images

, $ alpha = 30){$ Temp = pathinfo ($ srcImg );$ Name = $ temp [basename];$ Path = $ temp [dirname];$ Exte = $ temp [extension];$ Savename = $ savename? $ Savename: $ name;$ Savepath = $ savepath? $ Savepath: $ path;$ Savefile = $ savepath. "/". $ savename;$ Srcinfo = @ getimagesize ($ srcImg );If (! $ Srcinfo ){Return-1; // The original file does not exist.}$ Waterinfo = @ getimagesize ($ waterImg );If (! $ Wateri

Php allows you to add watermarks to images.

, $ savename = null, $ positon = 5, $ alpha = 30) { $ Temp = pathinfo ($ srcImg ); $ Name = $ temp ['basename']; $ Path = $ temp ['dirname']; $ Exte = $ temp ['extension']; $ Savename = $ savename? $ Savename: $ name; $ Savepath = $ savepath? $ Savepath: $ path; $ Savefile = $ savepath. '/'. $ savename; $ Srcinfo = @ getimagesize ($ srcImg ); If (! $ Srcinfo ){ Return-1; // the original file does not exist. } $ Waterinfo = @ getimagesize ($ waterImg )

PHP image Processing

Synthetic picture (watermark) function Img_water_mark ($SRCIMG, $WATERIMG, $savename, $savepath = ' Public/images/wxqrcode ', $positon = 3, $ ALPHA=100) {//$savename =time (). JPG '; $temp = PathInfo ($SRCIMG); $name = $temp [' basename ']; $path = $temp [' dirname ']; $exte = $temp [' extension ']; $savename = $savename? $savename: $name; $savepath = $savepath? $savepath: $path; $savefile = $savepath. ' /'. $savename; $srcinfo = @getimagesize ($SRCIMG)

Php _ PHP Tutorial-php Tutorial

img_water_mark ($ srcImg, $ waterImg, $ savepath = null, $ savename = null, $ positon = 5, $ alpha = 30) { $ Temp = pathinfo ($ srcImg ); $ Name = $ temp [basename]; $ Path = $ temp [dirname]; $ Exte = $ temp [extension]; $ Savename = $ savename? $ Savename: $ name; $ Savepath = $ savepath? $ Savepath: $ path; $ Savefile = $ savepath./. $ savename; $ Srcinfo = @ getimagesize ($ srcImg ); If (! $ Srcinfo ){ Return-1; // The original file does not exist. } $

PHP Image Add Watermark function Simple example

= $temp [' basename ']; $path = $temp [' dirname ']; $exte = $temp [' extension ']; $savename = $savename? $savename: $name; $savepath = $savepath? $savepath: $path; $savefile = $savepath. ' /'. $savename; $srcinfo = @getimagesize ($SRCIMG); if (! $srcinfo) { return-1; The original file does not exist } $waterinfo = @getimagesize ($WATERIMG); if (! $waterinfo

A small example of PHP images and watermarks

']; $path = $temp [' dirname ']; $exte = $temp [' extension ']; $savename = $savename? $savename: $name; $savepath = $savepath? $savepath: $path; $savefile = $savepath. ' /'. $savename; $srcinfo = @getimagesize ($SRCIMG); if (! $srcinfo) { return-1; The original file does not exist } $waterinfo = @getimagesize ($WATERIMG); if (! $waterinfo) { Retu

PHP implementation Picture Add watermark function _php instance

; $savepath = $savepath? $savepath: $path; $savefile = $savepath. ' /'. $savename; $srcinfo = @getimagesize ($SRCIMG); if (! $srcinfo) { return-1; The original file does not exist } $waterinfo = @getimagesize ($WATERIMG); if (! $waterinfo) { Return-2; Watermark picture does not exist } $SRCIMGOBJ = Image_create_from_ext ($SRCIMG); if (! $srcImgObj) { return-3; Original file image object failed

PHP adds watermarks to images

maintenance. Here is the key to give the following function name, that is, the realization of the watermark function is mainly by these functions function operation1.imagecreatefromjpeg//Open JPG image 2.imagecreatefromgif//open GIF picture3.imagecreatefrompng//Open PNG image4.imagecreatefromwbmp//Open wbmp picture (less)5.getimagesize//Get picture size information6.imagecopymerge//Integrate multiple images (the main function of adding watermarks)7.imagejpeg//Save JPG Images8.imagegif//Save GIF

PHP file upload and upload pictures plus watermark example

! '); Note: If you have other table field names in the upload we need to take advantage of the post to accept it, otherwise you may not accept the value. After you complete the above steps, you will be able to add a watermark to your uploaded images. Here's a little demo I wrote.Watermark Class The code is as follows Copy Code /*** Add Watermark Class* Jones Taiwan Blog*/Class water{Private $imgPath; Picture pathPublic function __construct ($imgPath = "./")

A method of randomly generating watermark image function in PHP

']); /** @var Create white font for text */$textColor = imagecolorallocate ($image, 255, 255, 255); /** @var Font file path */$font = $_server[' Document_root '). ' /public/font/simhei.ttf '; $x = 18;//text start position x coordinate $y = 50;//text start position y-coordinate/** Text Write picture */$angle = 0;//angle 0 imagettftext ($image, $this->fontsize, $angle, $x, $y, $textColor, $font, $this->t EXT); /** @var watermark Picture path **/$waterImgPath = $this->randwaterimage ()

Add watermarks to images and generate scaling charts using PHP

($ waterImgOn) {// watermark image valid // Watermark information $ WaterInfo = getimagesize ($ waterImg ); // Watermark width $ WaterWidth = $ waterInfo [0]; // Watermark height $ WaterHeight = $ waterInfo [1]; // Create different types of gif jpeg png based on different situations $ W_img = null; Switch ($

Total Pages: 2 1 2 Go to: Go

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.